package Test;

import javax.xml.transform.Source;

/**
 * @author caesar
 * @date 2025/7/11
 * @Description:
 * @apiNote
 */
public class Test1 {
    static int x, y, z;

    static {
        int x = 5;
        x--;
    }

    static {
        x--;
    }

    public static void main(String[] args) {
        System.out.println("x=" + x);
        z--;
        method();
        //x = -1,y=0,z=1
        System.out.println("result:" + (z + y + ++z));
        System.out.println("x = " + x);
        System.out.println("y = " + y);
        System.out.println("z = " + z);
    }

    public static void method() {
        y = z++ + ++z;//-1+1=0
    }
}
